#!/usr/bin/env bash

npm run build:stage

tar -czf dist.tgz ./dist/*

scp dist.tgz root@47.95.208.193:/opt/nginx/html

ssh root@47.95.208.193 "cd /opt/nginx/html;rm -fr crmeb_csqx_test; tar -xvf dist.tgz; mv dist crmeb_csqx_test ;rm -rf dist.tgz; exit;"

rm dist.tgz;

echo "✅  后台管理 部署成功"
exit

